<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
    <!--自适应界面,如果出现,在某些设备出现界面偏小的话,检查一下有没有加入这句 -->
    <meta http-equiv="Content-type" name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=no, width=device-width">

	<link rel="stylesheet" href="../css/jquery.mobile-1.0.1.min.css" />
	
	<script src="../js/jquery.js"></script>
	<script src="../js/jquery.mobile-1.0.1.min.js"></script>
	<script src="../js/cordova-1.5.0.js"></script>
	<script src="../js/geodevice.js"></script>
	<script type="text/javascript" src="http://api.map.baidu.com/api?v=1.2"></script>
	
	<script type="text/javascript">
	
        function initialize() {
			var mp = new BMap.Map('main4Content');
			//mp.addControl(new BMap.NavigationControl());  
			//mp.addControl(new BMap.ScaleControl());  
			//mp.addControl(new BMap.OverviewMapControl());  
			//mp.addControl(new BMap.MapTypeControl());  
			//mp.setCurrentCity("广州"); // 仅当设置城市信息时，MapTypeControl的切换功能才能可用
			
			var point = new BMap.Point(116.404, 39.915);  
			mp.centerAndZoom(point, 15);  
			
			var marker = new BMap.Marker(point);        // 创建标注  
			mp.addOverlay(marker);                     // 将标注添加到地图中
	
		}
	
		function loadScript() {
			var script = document.createElement("script");
	 		script.src = "http://api.map.baidu.com/api?v=1.2&callback=initialize";
			document.body.appendChild(script);
		}
	
		window.onload = loadScript;

    </script>
</head>
<body>

    <div data-role="header" data-position="fixed">
			<h1>地图定位</h1>
	</div>
	<div data-role="content" id="main4Content" style="width:100%;height:420px">
	
	</div>

	<div data-role="footer" data-position="fixed">
		<div data-role="navbar">
				<ul>
					<li><a href="main.html" data-icon="grid"  rel="external">工作</a></li>
					<li><a href="main2.html" data-icon="info"  rel="external">资讯</a></li>
					<li><a href="main3.html" data-icon="gear"  rel="external">设置</a></li>
					<li><a href="#" data-icon="search" class="ui-btn-active" >地图</a></li>
				</ul>
		</div>
	</div>

</body>

</html>
